<template>
  <div>
    <el-breadcrumb separator=">">
      <el-breadcrumb-item :to="{ path: '/home' }">首页</el-breadcrumb-item>
      <el-breadcrumb-item>权限管理</el-breadcrumb-item>
      <el-breadcrumb-item>权限列表</el-breadcrumb-item>
    </el-breadcrumb>
    <el-table :data="list" border style="width: 100%">
      <el-table-column align="center" label="序号" width="50">
        <template slot-scope="{ $index }">
          {{ $index }}
        </template>
      </el-table-column>
      <el-table-column align="center" prop="authName" label="权限名称">
      </el-table-column>
      <el-table-column
        align="center"
        prop="path"
        label="路径"
      ></el-table-column>
      <el-table-column align="center" prop="level" label="权限等级">
        <template slot-scope="{ row }">
          <el-tag v-if="row.level == '0'" type="primary">一级</el-tag>
          <el-tag v-else-if="row.level == '1'" type="success">二级</el-tag>
          <el-tag v-else type="warning">三级</el-tag>
        </template>
      </el-table-column>
    </el-table>
  </div>
</template>
<script>
import { getqxList } from '@/api/quanxian'
export default {
  name: 'qxList',
  data () {
    return {
      list: []
    }
  },
  async created () {
    const res = await getqxList()
    // console.log(res, 898989)
    this.list = res.data
  },
  computed: {
  },
  methods: {
  }
}
</script>
<style lang='scss'  scoped>
</style>
